package com.taffywen.study.spring_cloud_learn.controller;


import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@Slf4j
public class DemoController {

    @Value("${demo:demo}")
    private String demo;
    @RequestMapping("/demo")
    public String demo(){
        log.info("demo-------------"+demo);
        return "demo--->"+demo;
    }

    @RequestMapping("/getSpringCloudLearnDemo")
    public String getSpringCloudLearnDemo(){
        log.info("getSpringCloudLearnDemo-------------"+demo);
        return "getSpringCloudLearnDemo" + demo;
    }
}
